#!/usr/bin/env bash

# Train and test STAViS audiovisual models for all splits

base_path='./experiments'

# split=1
# results_path='split'${split}'_results'
# mkdir -p ${base_path}'/'${results_path}

# python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
#     --explain "basic experiment without audio" \
#     --no_test \
#     --audiovisual "" --checkpoint 10 --n_epochs 10 \
#     --root_path ${base_path} --result_path visual_split1_basic \
#     --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth \
#     --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
#   	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
#   	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
#   	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
#   	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
#   	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
#   	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
#   	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
#   	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt

# python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
#     --pool_layer tempSE \
#     --explain "temporal se pool" \
#     --no_test \
#     --audiovisual "" --checkpoint 10 --n_epochs 10 \
#     --root_path ${base_path} --result_path visual_split1_tempSE \
#     --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth  \
#     --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
#   	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
#   	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
#   	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
#   	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
#   	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
#   	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
#   	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
#   	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt

# python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
#     --pool_layer tempAvg \
#     --explain "temporal average pool" \
#     --no_test \
#     --audiovisual "" --checkpoint 10 --n_epochs 10 \
#     --root_path ${base_path} --result_path audiovisual_split1_tempAvg \
#     --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth \
#     --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
#   	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
#   	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
#   	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
#   	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
#   	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
#   	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
#   	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
#   	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt

# python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
#     --pool_layer tempAvg \
#     --use_tempAvg_fc \
#     --explain "temporal average pool with fc" \
#     --no_test \
#     --audiovisual "" --checkpoint 10 --n_epochs 10 \
#     --root_path ${base_path} --result_path audiovisual_split1_tempAvgFC \
#     --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth  \
#     --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
#   	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
#   	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
#   	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
#   	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
#   	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
#   	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
#   	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
#   	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt

# python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
#     --reduction 1 \
#     --pool_layer tempAvg \
#     --explain "temporal average pool" \
#     --no_test \
#     --audiovisual "" --checkpoint 10 --n_epochs 10 \
#     --root_path ${base_path} --result_path audiovisual_split1_tempAvg \
#     --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth \
#     --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
#   	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
#   	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
#   	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
#   	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
#   	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
#   	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
#   	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
#   	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt

# python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
#     --reduction 2 \
#     --pool_layer tempAvg \
#     --explain "temporal average pool" \
#     --no_test \
#     --audiovisual "" --checkpoint 10 --n_epochs 10 \
#     --root_path ${base_path} \
#     --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth \
#     --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
#   	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
#   	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
#   	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
#   	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
#   	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
#   	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
#   	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
#   	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt
#
# python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
#     --reduction 3 \
#     --pool_layer tempAvg \
#     --explain "temporal average pool" \
#     --no_test \
#     --audiovisual "" --checkpoint 10 --n_epochs 10 \
#     --root_path ${base_path} \
#     --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth \
#     --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
#   	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
#   	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
#   	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
#   	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
#   	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
#   	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
#   	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
#   	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt

# python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
#     --explain "basic experiment without audio" \
#     --no_test \
#     --audiovisual "" --checkpoint 10 --n_epochs 60 \
#     --root_path ${base_path} \
#     --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth \
#     --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
#   	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
#   	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
#   	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
#   	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
#   	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
#   	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
#   	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
#   	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt

# python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
#     --reduction 2 \
#     --pool_layer tempAvg \
#     --explain "temporal average pool" \
#     --no_test \
#     --audiovisual "" --checkpoint 10 --n_epochs 60 \
#     --root_path ${base_path} \
#     --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth \
#     --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
#   	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
#   	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
#   	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
#   	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
#   	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
#   	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
#   	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
#   	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
#   	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt

split=3
python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
    --explain "basic experiment without audio split3" \
    --no_test \
    --audiovisual "" --checkpoint 10 --n_epochs 60 \
    --root_path ${base_path} \
    --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth \
    --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
  	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
  	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
  	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
  	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
  	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
  	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
  	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
  	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
  	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
  	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt


split=2
python main.py --gpu_devices 0,1 --batch_size 128 --n_threads 12 \
    --explain "basic experiment without audio split2" \
    --audiovisual "" --checkpoint 10 --n_epochs 60 \
    --root_path ${base_path} \
    --pretrain_path ./data/pretrained_models/resnet-50-kinetics.pth \
    --audio_pretrain_path ./data/pretrained_models/soundnet8.pth \
  	--annotation_path_coutrot1_train ./data/fold_lists/Coutrot_db1_list_train_${split}_fps.txt \
  	--annotation_path_coutrot1_test ./data/fold_lists/Coutrot_db1_list_test_${split}_fps.txt \
  	--annotation_path_coutrot2_train ./data/fold_lists/Coutrot_db2_list_train_${split}_fps.txt \
  	--annotation_path_coutrot2_test ./data/fold_lists/Coutrot_db2_list_test_${split}_fps.txt \
  	--annotation_path_summe_train ./data/fold_lists/SumMe_list_train_${split}_fps.txt \
  	--annotation_path_summe_test ./data/fold_lists/SumMe_list_test_${split}_fps.txt \
  	--annotation_path_etmd_train ./data/fold_lists/ETMD_av_list_train_${split}_fps.txt \
  	--annotation_path_etmd_test ./data/fold_lists/ETMD_av_list_test_${split}_fps.txt \
  	--annotation_path_avad_train ./data/fold_lists/AVAD_list_train_${split}_fps.txt \
  	--annotation_path_avad_test ./data/fold_lists/AVAD_list_test_${split}_fps.txt
